<div class="contents">
  <ol class="breadcrumb">
    <li><a href="#/index/panel">首页</a></li>
    <li><a href="#/link/list">友情链接列表</a></li>
    <li class="active">新增友情链接</li>
  </ol>
  <form class="form-horizontal" role="form" name="form" ng-submit="save()" novalidate> 
    <div class="form-group" ng-class="{'has-error':form.title.$invalid && form.title.$dirty}">
      <label for="advertTitleInput" class="col-sm-2 control-label">文字</label>
      <div class="col-sm-5">
        <input type="text" class="form-control" id="advertTitleInput" placeholder="文字" name="title" ng-model="ad.title" required="required">
      </div>
    </div>
    <div class="form-group" ng-class="{'has-error':form.link.$invalid && form.link.$dirty}">
      <label for="advertLinkInput" class="col-sm-2 control-label">链接地址</label>
      <div class="col-sm-5">
        <input type="text" class="form-control" id="advertLinkInput" placeholder="链接地址" name="link" ng-model="ad.url" required="required">
      </div>
    </div>
    <div class="form-group" ng-class="{'has-error':form.sort.$invalid && form.sort.$dirty}">
      <label for="advertSortInput" class="col-sm-2 control-label">排序值</label>
      <div class="col-sm-5">
        <input type="number" class="form-control" id="advertSortInput" placeholder="排序值，越大越排前" value="10" name="sort" ng-model="ad.index" required="required">
      </div>
    </div>
    <!--
    <div class="form-group">
      <label for="advertSortInput" class="col-sm-2 control-label">状态</label>
      <div class="col-sm-5">
        <label class="radio-inline">
          <input type="radio" name="status" value="01" ng-model="ad.status">上架
        </label>
        <label class="radio-inline">
          <input type="radio" name="status" value="02" ng-model="ad.status">下架
        </label>
      </div>
    </div>
    -->
    <div class="form-group">
      <div class="col-sm-offset-2 col-sm-5">
        <button type="submit" class="btn btn-default">提交</button>
      </div>
    </div>
  </form>
</div>
<div load-script src="'/static/jquery.jUploader-1.01.js?5'" call-back="" charset="utf-8" ></div>
